home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1996 #14
/
Monster Media No. 14 (April 1996) (Monster Media, Inc.).ISO
/
os2
/
diskct10.zip
/
INSTALL.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1996-01-13
|
2KB
|
89 lines
/* install DiskCat */
call RxFuncAdd "SysLoadFuncs","RexxUtil","SysLoadFuncs"
call SysLoadFuncs
call SysCls
say
say "DiskCat install utility"
say
say
say "please enter target drive/path :"
say "(default C:\DiskCat)"
pos = SysCurPos(4,34)
pull laufwerk
pos = SysCurPos(7,0)
map = SysDriveMap("A:")
ziellw = "C:\DiskCat\"
dp = ":"
bs = "\"
if substr(laufwerk,1,1) = ""
then ziel = ziellw
else ziel = laufwerk
if substr(ziel,2,1) = ""
then ziel = insert(dp,ziel,1)
if substr(ziel,3,1) = ""
then ziel = insert(bs,ziel,2)
if wordpos(substr(ziel,1,2),map) = 0
then do
say "drive does not exist!"
exit
end
if substr(ziel,length(ziel),1) = bs
then ziel = delstr(ziel,length(ziel),1)
if length(ziel) > 3 then do
rc = SysFileTree(ziel,"ergebnis","D")
dirfound = 0
if ergebnis.0 = 0 then do
say "directory does not exist, create ? y/n :"
pos = SysCurPos(7,45)
pull antwort
if antwort = "Y" then do
rc = SysMkDir(ziel)
if rc > 0 then do
say "could not create target directory !!!"
exit
end
else do
rc = SysFileTree(ziel,"ergebnis","D")
if ergebnis.0 > 0 then
dirfound = 1
end
end
end
else
dirfound = 1
end
if dirfound = 1 then do
"@copy diskcat.exe >NUL" ziel
"@copy diskcat.msg >NUL" ziel
options = "EXENAME=" || ziel || "DiskCat.EXE;"
ziel = delstr(ziel,length(ziel),1)
options = options || "STARTUPDIR=" || ziel || ";"
rc=SysCreateObject('WPProgram',titel,'<WP_DESKTOP>',options,'u');
drive = substr(ziel,1,2)
drive
"@cd "ziel
"start diskcat.exe "ziel
end
call SysDropFuncs
exit